home *** CD-ROM | disk | FTP | other *** search
- program SPELLCHK;
- { used to check the SPELLER.LIS file for out of place words.}
- type
- files = text;
- var
- filecheck : files;
- word, oldword : string [24];
- wordcount, line : integer;
- begin
- assign (filecheck, 'speller.lis');
- reset (filecheck);
- word := '';
- oldword := '';
- ClrScr;
- gotoxy (30,1);
- writeln ('CHECKING SPELLER.LIS');
- gotoxy (30,3);
- write (' WORD : ');
- gotoxy (1, 5);
- line := 5;
- readln (filecheck, word);
- wordcount := 1;
- while not eof (filecheck) do begin
- oldword := word;
- readln (filecheck, word);
- wordcount := wordcount+1;
- gotoxy (41,3);
- write (wordcount);
- if not (word > oldword) then begin
- line := line+1;
- gotoxy (1,line);
- writeln (oldword, ' ', word);
- end;
- end;
- close (filecheck);
- end.
-
-